<!DOCTYPE html>
<html>
{include file="public/head" /}
<body>
          <div class="nav-tabs-custom" style="box-shadow:0 0 0 0; margin-top:1px;">
            <ul class="nav nav-tabs">
            <li class="active"><a href="#basic" data-toggle="tab">基础设置</a></li>
            <li><a href="#gao" data-toggle="tab">高级设置</a></li>
            <li><a href="#moban" data-toggle="tab">模版设置</a></li>                    
            </ul> 
            <form id="myform" class="myform form-horizontal"  method="post" action="{:url('update')}">
            <input type="hidden" name="id" value="{$info['id']}"> 
<div class="box-body">
          <div class="row">
            <div class="col-md-12">
           <div class="tab-content tab-fade fade active in " id="basic">
               <div class="input-group margin">
                <div class="input-group-btn">
                  <span class="btn btn-default form-left-btn">模型标识：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="name" value="{$info['name']|default=''}" autocomplete="off"  required="required" placeholder="请输入文档模型标识">
              </div>
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">模型名称：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="title" value="{$info.title|default=''}"  autocomplete="off"  required="required" placeholder="请输入模型的名称">
              </div> 
               <div class="input-group margin">
                <div class="input-group-btn">
                  <span class="btn btn-default form-left-btn">模型类型：</span>
                </div>
                <!-- /btn-group -->
                <select name="extend" class="form-control select2" disabled>
			<option value="0" {if condition="$info['extend'] eq '0'"}selected{/if}>--请选择--</option>
			<option value="1" {if condition="$info['extend'] eq '1'"}selected{/if}>文档模型</option>
			<option value="2" {if condition="$info['extend'] eq '2'"}selected{/if}>独立模型</option>
                </select>
              </div> 
              
               <div class="input-group margin">
                <div class="input-group-btn">
                  <span class="btn btn-default form-left-btn">会员显示：</span>
                </div>
                <!-- /btn-group -->
                <select name="is_user_show" class="form-control select2">
			<option value="1" {if $info['is_user_show'] ==1}selected="selected"{/if}>是</option>
			<option value="0" {if $info['is_user_show'] ==0}selected="selected"{/if}>否</option>
                </select>
              </div>               
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">模型图标：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="icon" value="{$info.icon|default=''}">
              </div>
                                                                                      
            </div>  
            <!-- /.basic -->
           <div class="tab-content tab-fade fade " id="gao">
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn" style="margin-top:-56px;">别名定义：</span>
                </div>
                <!-- /btn-group -->
               <textarea name="attribute_alias" class="form-control" style="height: 90px">{$info.attribute_alias|default=''}</textarea>
              </div> 
              
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">表单分组：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="field_group" value="{$info.field_group|default=''}"  placeholder="用于表单显示的分组，以及设置该模型表单排序的显示">
              </div> 
               <div class="input-group margin">
                <div class="input-group-btn">
                  <span class="btn btn-default form-left-btn">表单排序：</span>
                </div>
                <span class="form-control">直接拖动进行排序</span>
                </div>
                <!-- /btn-group -->
        <div style="margin: 10px 0px 10px 10px">
         <div class="form-group">
							<div class="col-xs-12 boards" id="field_group_sort">
                            {php}$count=10/count(parse_field_attr($info['field_group']));{/php}
							{volist name=":parse_field_attr($info['field_group'])" id="vo"}
                            <div  style="width:{$count}0%;float:left; padding-right:10px">
								<div class="board panel panel-info" >
									<div class="panel-heading">{$vo}</div>
									<div class="panel-body">
										<div class="board-list" data-group="{$key}">
										{foreach name="fields" item="field" key="k"}
											{if (($field['group'] == -1) or ($field['group'] eq $key))}
												<div class="board-item">
													<span data="{$field['id']}">{$field['title']} [{$field['name']}]</span>
													<input type="hidden" name="field_sort[{$key}][]" value="{$field['id']}"/>
												</div>
												{php}
												unset($fields[$k]);
												{/php}
											{/if}
										{/foreach}
										</div>
									</div>
								</div>
                                </div>
							{/volist}
							</div>
						
						</div>  
        </div>
               
              
               <div class="input-group margin">
                <div class="input-group-btn">
                  <span class="btn btn-default form-left-btn" style="margin-top:-56px;">列表定义：</span>
                </div>
                <!-- /btn-group -->
                <textarea name="list_grid" class="form-control" style="height: 90px">{$info.list_grid|default=''}</textarea>
              </div>               
               <div class="input-group margin">
                <div class="input-group-btn">
                  <span class="btn btn-default form-left-btn">需要主键：</span>
                </div>
                <!-- /btn-group -->
                <select name="need_pk" class="form-control select2">
			    <option value="1" selected="selected">是</option>
			    <option value="0">否</option>
                </select>
              </div> 
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">默认搜索字段：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="search_key" value="{$info.search_key|default=''}" placeholder="默认列表模板的默认搜索项">
              </div>
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">高级搜索字段：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="search_list" value="{$info.search_list|default=''}" placeholder="默认列表模板的高级搜索项">
              </div>
                                                                                      
            </div> 
            <!-- /.gao -->
            
            <div class="tab-content tab-fade fade " id="moban">
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">后台列表模板：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="template_list" value="{$info['template_list']|default=''}" autocomplete="off"  placeholder="（自定义的列表模板，放在lib/admin/viewn/模型标识目录/下，不写则使用默认模板）" disabled>
              </div>
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">后台新增模板：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="template_add" value="{$info['template_add']|default=''}" autocomplete="off"  placeholder="（自定义的列表模板，放在lib/admin/viewn/模型标识目录/下，不写则使用默认模板）" disabled>
              </div>              
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">后台新增模板：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="template_edit" value="{$info['template_edit']|default=''}" autocomplete="off"  placeholder="（自定义的列表模板，放在lib/admin/viewn/模型标识目录/下，不写则使用默认模板）" disabled>
              </div>                            
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">前台栏目模板：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="template_list_skin" value="{$info['template_list_skin']|default=''}" autocomplete="off"  placeholder="请放到模版文件夹中" disabled>
              </div> 
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">前台检索模板：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="template_list_type" value="{$info['template_list_type']|default=''}" autocomplete="off"  placeholder="请放到模版文件夹中" disabled>
              </div>
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">前台内容模板：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="template_list_detail" value="{$info['template_list_detail']|default=''}" autocomplete="off"  placeholder="请放到模版文件夹中" disabled>
              </div>              
               <div class="input-group margin">
                <div class="input-group-btn">
                <span class="btn btn-default form-left-btn">前台播放模板：</span>
                </div>
                <!-- /btn-group -->
                <input type="text" class="form-control" name="template_list_play" value="{$info['template_list_play']|default=''}" autocomplete="off"  placeholder="请放到模版文件夹中" disabled>
              </div>                             
                          
             </div> 
            <!-- /.moban -->
                    
          </div>
          </div>
          <!-- /.row -->
          
        <div class="box-footer {notempty name=":request()->param('dialog')"}hidden{/notempty} layer-footer">
          <div  class="footer-btn">
               <button type="submit" class="btn btn-success btn-embossed">确定</button>
               <button type="reset" class="btn btn-default btn-embossed">重置</button>
               {notempty name=":request()->param('dialog')"}
               <button type="reset" class="btn btn-primary btn-embossed btn-close" onClick="layer.closeAll();"> 关闭</button>
               {/notempty}
            </div>
       </div>
       <!-- /.box-footer -->     
</div>
<!-- /.box-body --> 
</form>
</div>
<!-- /.nav-tabs-custom -->    
{include file="public/footer" /}
<script type="text/javascript">
$(document).ready(function(){
	zanpian.cms.model();
});	
</script>
</body>
</html>
